package com.secret.chain.secretchain.mapper;

import com.secret.chain.secretchain.domain.entity.Answer;
import com.secret.chain.secretchain.domain.entity.Comment;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Select;

@Mapper
public interface AnswerMapper {
    @Select("select * from answer where problem_id = #{problemId}")
    Answer queryByProblemId(Integer id);


    void insert(Answer answer);

    @Delete("delete from answer where id = #{id}")
    void delete(Integer id);

    void update(Answer answer);
}
